<?php
class BookTest extends Kenxu_Unit_TestCase {
	/**
	 * @var Book $_modBook
	 */
	private $_modBook = null ;
	
	function setUp(){
		/* Setup Routine */
		$this->_modBook = new Book() ;
	}
	
	
	function fetchBooksTest(){
		
		$books = $this->_modBook->fetchBooks() ;

		Kenxu_Unit_Assert::assertThat( count($books),array(array('equal',3, '图书个数为3')) ,'测试图书元素' );
		Kenxu_Unit_Assert::assertThat( !$books,array(array('not_empty','值不能为空')) ,'测试图书元素' );
		Kenxu_Unit_Assert::assertNotNull( !$books,'图书表中数据为空' );
	}
		
	function tearDown(){
		/* Tear Down Routine */
		$this->_modBook = null ;
	}
}